<div class="container-fluid">
    <div id="pad-wrapper">
        <div class="table-wrapper products-table section">

            <div class="row-fluid head">
                <div class="span12">
                    <h4>代言商品列表</h4>
                </div>
            </div>

            <form action="" method="get" name="search">
                <div class="row-fluid filter-block">
                    <div class="pull-left">
                        <a class="btn-flat success new-product" href="index">添加</a>
                    </div>
<!--                    <div class="pull-right">-->
<!--                        主标题：-->
<!--                        <input type="text" class="search" name="title" value="--><?php //echo $title ?><!--"/>-->
<!--                        <input type="hidden" name="type" value="--><?php //echo $type ?><!--"/>-->
<!--                        <a class="btn-flat success" onclick="document.forms['search'].submit();">搜索</a>-->
<!--                    </div>-->
                </div>
            </form>

            <div class="row-fluid">
                <table class="table table-hover">
                    <thead>
                    <tr>
                        <th class="span3"><span class="line"></span>ID</th>
                        <th class="span3"><span class="line"></span>商品名称</th>
                        <th class="span3"><span class="line"></span>商品售价</th>
                        <th class="span3"><span class="line"></span>首次折扣</th>
                        <th class="span3"><span class="line"></span>一级分成比例</th>
                        <th class="span3"><span class="line"></span>二级分成比例</th>
                        <th class="span3"><span class="line"></span>三级分成比例</th>
                        <th class="span3"><span class="line"></span>操作</th>
                    </tr>
                    </thead>
                    <tbody>
                    <?php foreach ($list as $item): ?>
                        <!-- row -->
                        <tr class="first">
                            <td><?= $item['distribution_id'] ?></td>
                            <td><?= $item['product_name'] ?></td>
                            <td><?= $item['distribution_price'] ?></td>
                            <td><?= $item['first_discount'] ?></td>
                            <td><?=$item['level_1']?></td>
                            <td><?=$item['level_2']?></td>
                            <td><?=$item['level_3']?></td>
                            <td>
                                <button type="button" class=" btn-flat primary"
                                        onclick="window.location.href='index?id=<?=$item['distribution_id'] ?>'">
                                    编辑
                                </button>
                            </td>
                        </tr>
                    <?php endforeach; ?>
                    </tbody>
                </table>
            </div>


        </div>
    </div>
    <div class="pagination pull-right">
        <?= $page; ?>
    </div>
</div>